package com.shengqin.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.shengqin.entity.PlanReservationItem;
import com.shengqin.mapper.PlanReservationItemMapper;
import com.shengqin.service.IPlanReservationItemService;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class PlanReservationItemServiceImpl extends ServiceImpl<PlanReservationItemMapper, PlanReservationItem> implements IPlanReservationItemService {
    @Override
    public List<PlanReservationItem> listByPlanId(PlanReservationItem reservationItem) {
        QueryWrapper<PlanReservationItem> wrapper = new QueryWrapper<>();
        wrapper.lambda().eq(PlanReservationItem::getPlanId,reservationItem.getPlanId());
        return list(wrapper);
    }
}
